#ifndef BSP_LED_H__
#define BSP_LED_H__

#include "gpio.h"
#include "stm32f4xx.h"
#include "stm32f4xx_hal_gpio.h"

typedef enum { LEDR = 0, LEDG, LED_ALL } Led_enum_t;

class Led {
public:
  Led() { MX_GPIO_Init(); }

  /**
   * @description:Toggle Leds
   * @param {Led_enum_t} d @ref: LEDR,LEDG,LED_ALL
   * @return {*}
   * @Date: 2024-02-02 09:38:31
   * @LastEditors: Even
   */
  void LedToggle(Led_enum_t d);
  /**
   * @description:
   * @param {Led_enum_t} @ref: LEDR,LEDG,LED_ALL
   * @return {*}
   * @Date: 2024-02-02 09:46:50
   * @LastEditors: Even
   */
  void LedOn(Led_enum_t d);
  /**
   * @description:
   * @param {Led_enum_t} d @ref: LEDR,LEDG,LED_ALL
   * @return {*}
   * @Date: 2024-02-02 09:47:17
   * @LastEditors: Even
   */
  void LedOff(Led_enum_t d);

  void LedHandler(void *argument);
};

extern Led led;
#endif